<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>
<%@ taglib uri="http://displaytag.sf.net" prefix="display"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

<head>
 <sx:head extraLocales="en-us,nl-nl,de-de" />
</head>

<table width="100%" cellpadding="0" cellspacing="0">
	<tr>
		<td height="40" class="sectionheading bottom-border">Account Sheet</td>
	</tr>
	<tr>
		<td>
			<p>
				<font size="2"><a href="#">View Account</a> &gt; <s:property value="accountDetailList.userId" /> </font>
			</p>
			<form method="post" action="searchAccountSheet.htm" name="Accounts_Manager">
				<input name="userId" value="<s:property value="accountDetailList.id" />" type="hidden">
				<table width="100%" border="0">
					<tbody>
						<tr>
							<td nowrap="nowrap" width="20%">
								<b>&nbsp;Date From (dd/mm/yyyy):</b>
							</td>
							<td width="70%" nowrap="nowrap" width="40%">
								<sx:datetimepicker displayFormat="dd/MM/yyyy" value="%{'today'}" toggleType="wipe" toggleDuration="300" name="fromDate" />
								&nbsp;&nbsp;
								<b>To (dd/mm/yyyy):</b>
								<sx:datetimepicker displayFormat="dd/MM/yyyy" value="%{'today'}" toggleType="wipe" toggleDuration="300" name="toDate" />
							</td>
							<td width="20%">
								<input name="User" value="victor" type="hidden">
								<input name="btnSearch" value="Search" type="submit">
							</td>
						</tr>
					</tbody>
				</table>
				<display:table name="depositsList" pagesize="10" cellpadding="0" cellspacing="0" id="row" class="verdana12blacknormal">
					<display:column title="#" headerClass="Table-Head" style="text-align: center">
						<c:out value="${row_rowNum}" />
					</display:column>
					<display:column headerClass="Table-Head" style="text-align: center" property="source" title="Description"  class="navi-link" />
					<display:column headerClass="Table-Head" style="text-align: center" title="Date" autolink="true">
						<s:date name="#attr.row.depositDate" format="dd MMMM, yyyy" />
					</display:column>
					<display:column headerClass="Table-Head" style="text-align: right" title="Debit" class="navi-link">
						<c:if test="${row.amount < 0}"><c:out value="${-1 * row.amount}" /></c:if>
					</display:column>
					<display:column headerClass="Table-Head" style="text-align: right" title="Credit" class="navi-link">
						<c:if test="${row.amount > 0}"><c:out value="${row.amount}" /></c:if>
					</display:column>
					<display:footer>
  						<tr>
  							<td height="23" class="Table-Head" style="padding: 0px 0px 0px 10px" colspan="3"><b>Current Account Balance:</b></td>
  							<td colspan="2" class="Table-Head" style="padding: 0px 10px 0px 0px" align="right"><b><s:property value="accountDetailList.currentBalance" /></b></td>
  						<tr>
  					</display:footer>
				</display:table>
			</form>
		</td>
	</tr>
</table>
